import pkgutil
import logging

default_app_config = 'cube.apps.CubeConfig'

def autodiscover_providers():
    for loader, pkg_name, is_pkg in pkgutil.iter_modules(['cube/providers']):
        try:
            __import__('cube.providers.' + pkg_name)
        except ImportError as e:
            logging.error(e.message)

def autodiscover_configs():
    __import__('cube.configs')


autodiscover_providers()
autodiscover_configs()
